package com.naiterui.ehp.bs.b2c.pharmacy.entity;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Version;

import lombok.Data;

/**
 * <pre>
 *      合作药店
 * </pre>
 *
 * @author 王泽浩
 * @date 2019-07-02 10:32
 * @since 1.0.0
 */
@Data
@Entity
@Table(name = "p_warehouse")
public class Warehouse implements java.io.Serializable {

    private static final long serialVersionUID = -3834507674482656978L;

    /**
     * 是否冻结  正常
     */
    public static final int STATUS_NORMAL = 0;

    /**
     * 是否冻结  停用
     */
    public static final int STATUS_DISABLE = 1;

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Column(name = "id", nullable = false)
    private Long id;
    /**
     * 商家编码
     */
    @Column(name = "code")
    private String code;
    /**
     * 商家名称
     */
    @Column(name = "name")
    private String name;
    /**
     * 商家联系人
     */
    @Column(name = "linkman")
    private String linkman;
    /**
     * 商家联系电话
     */
    @Column(name = "phone")
    private String phone;
    /**
     * 邮箱
     */
    @Column(name = "email")
    private String email;
    /**
     * 合作商品数
     */
    @Column(name = "number")
    private Integer number;

    /**
     * 城市ID
     */
    @Column(name = "city_id")
    private Long cityId;

    /**
     * 详细地址
     */
    @Column(name = "address")
    private String address;

    /**
     * 状态:是否停用 0:启用。1:停用
     */
    @Column(name = "status")
    private Integer status;

    /**
     * 创建时间
     */
    @Column(name = "created_at")
    private Date createdAt;

    /**
     * 创建人
     */
    @Column(name = "created_by")
    private String createdBy;

    /**
     * 修改时间
     */
    @Column(name = "changed_at")
    private Date changedAt;

    /**
     * 修改人
     */
    @Column(name = "changed_by")
    private String changedBy;

    /**
     * 乐观锁
     */
    @Version
    private Integer version;
}
